QT       += core gui network

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

CONFIG += c++17

# You can make your code fail to compile if it uses deprecated APIs.
# In order to do so, uncomment the following line.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000    # disables all the APIs deprecated before Qt 6.0.0
DEFINES+=QT_NO_DEPRECATED_WARNINGS

if(contains(DEFINES,linux-g++-qt5)){
        TARGET = desktop-assist-qt5
}
if(contains(DEFINES,linux-g++-qt6)){
        TARGET = desktop-assist-qt6
}
if(contains(DEFINES,mingw)){
        TARGET = desktop-assist-win
}
if(contains(DEFINES,aarch64)){
        TARGET = desktop-assist-arm
}

SOURCES += \
    DAFuncTools.cpp \
    DAHoliday.cpp \
    DASetting.cpp \
    DASystemInfo.cpp \
    DATime.cpp \
    DATray.cpp \
    SysInfo/SysInfo.cpp \
    SysInfo/SysInfoImpl.cpp \
    main.cpp \
    DesktopAssist.cpp

HEADERS += \
    DAFuncTools.h \
    DAHoliday.h \
    DASetting.h \
    DASystemInfo.h \
    DATime.h \
    DATray.h \
    DesktopAssist.h \
    SysInfo/SysInfo.h \
    SysInfo/SysInfoImpl.h

DESTDIR += $$PWD/../bin

# Default rules for deployment.
qnx: target.path = bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target

win32{
    LIBS+= -liphlpapi
}
RESOURCES += \
    src.qrc

DISTFILES += \
    README.md
